package com.kitty.game.activity.controller;

import com.kitty.game.activity.message.ReqSwitchShuaDaoLevel;
import com.kitty.game.activity.service.ShuaDaoService;
import com.kitty.game.fixed.message.Fixedteamstartdata;
import com.kitty.game.role.model.Role;
import com.kitty.game.shidao.ShidaoService;
import com.kitty.mina.annotation.RequestMapping;
import com.kitty.mina.cache.SessionUtils;
import org.apache.mina.core.session.IoSession;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;

@Controller
public class ShuaDaoController {
    @Autowired
    ShuaDaoService shuaDaoService;
    @RequestMapping
    public void updateShuaDaoState(IoSession session, ReqSwitchShuaDaoLevel reqSwitchShuaDaoLevel){
        Role role = SessionUtils.getRoleBySession(session);
        shuaDaoService.updateShuaDaoState(role,reqSwitchShuaDaoLevel);
    }
}
